<%@ page contentType="text/html; charset=UTF-8"%>
<%@ taglib uri="/struts-tags" prefix="s"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<title>条码商品信息</title>
		<meta http-equiv="Pragma" content="no-cache" />
		<%@ include file="/user_comm.jsp"%>
	<link href="<%=request.getContextPath()%>/css/prop.css" type="text/css" rel="stylesheet"/>
	<script>
		function selProduct(){
			var selMemberIds = checkboxvalue("chkSon");
			if (selMemberIds == "") {
				alert("请选择一个商品");
				return;
			}
			var selArrIds=selMemberIds.split(",");
			if(selArrIds.length>1){
				alert("你只能选择一个商品");
				return;
			}
			var obj=new Array(selMemberIds);
			window.returnValue = obj;
			window.close();
		}
	</script>
	</head>
	<body>
		<div class="realRight ml10 l_bar">
					<div class="mybox">
						<div class="con Orbuy">
							<s:form name="formpage" action="bproduct_listall" namespace="/">
								<div class="pCenter">
									<div>
										<table class="favorRwList mt5">
											<tr>
												<th class="title"></th>
												<th class="title">
													商品名称
												</th>
												<th class="title">
													生产厂家
												</th>
												<th class="title">
													品牌
												</th>
												<th class="title">
													规格
												</th>
												<th class="title">
													包装方式
												</th>
												<th class="title">
													产品类别
												</th>
											</tr>
											
											<s:iterator value="#request.list" id="ca">
											<tr>
												<td>
													<input id="${ca.id}" name="chkSon" type="checkbox" value="${ca.id}"/>
												</td>
												<td>
													<s:property value="#ca.productName" />
												</td>
												<td>
													<s:property value="#ca.companyName" />
												</td>
												<td>
													<s:property value="convertBrand(#ca.brandId)" />
												</td>
												<td>
													<s:property value="#ca.guige" />
												</td>
												<td>
													<s:property value="#ca.pack" />
												</td>
												<td>
													<s:property value="#ca.type" />
												</td>
											</tr>
											</s:iterator>
										
											<s:if test="#request.list.size()==0">
												<tr>
													<td colspan="7">
														<span class='orange1 ml5'>没有满足条件的记录</span>
													</td>
												</tr>
											</s:if>
										
											<tr>
												<td colspan="8" valign="top" align="center">
														<br/>
														<a id="a_selMember" class="at_but b_2_g" href="#"
																onclick="selProduct()"> <u></u>确&nbsp;&nbsp;定</a>
												</td>
											</tr>
										</table>
										<s:property value="#request.allowpage" escape="false" />
									</div>
								</div>
							</s:form>
						</div>
					</div>
					<div>
					</div>
					<!--主体部分end-->
				</div>
	</body>
</html>
